package org.mics.organization.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

import org.hibernate.annotations.Where;
import org.mics.jpa.entity.BaseEntity;
import org.mics.organization.enums.DepartmentState;

import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 部门
 * @author mics
 * @date 2023-9-22
 * @version  1.0
 */
@Data
@Entity
@Table(name = "t_department")
@Where(clause = "bln_del = 0")
@EqualsAndHashCode(callSuper = false)
public class DepartmentDO extends BaseEntity{
	
    @Column(name = "name", columnDefinition = "varchar(32) comment '部门名称' ")
	private String name;
    
    @Column(name = "parent_id",  columnDefinition = "varchar(32) comment '上级部门id' ")
    private String parentId;
    
    @Column(name = "company_id", columnDefinition = "varchar(32) comment '公司id' ")
    private String companyId;
    
    @Column(name = "manager", columnDefinition = "varchar(32) comment '负责人' ")
    private String manager;
    
    @Column(name = "managerMobile", columnDefinition = "varchar(32) comment '负责人电话' ")
    private String managerMobile;
    
    @Column(name = "email", columnDefinition = "varchar(32) comment '邮箱' ")
    private String email;
	
    @Column(name = "department_state", columnDefinition = "varchar(32) comment '部门状态' ")
    private DepartmentState departmentState;
}
